<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    .container{
      width: 500px;
      height: 500px;
      background-color: orange;
    }
    .item{
      background-color: #f00;
      width: 100px;
      height: 100px;
      /* float: left; */
    }

    .box1{
      float: left;
      background-color: #0f0;
      margin-left: 20px;
    }
    .box2{
      float: left;
    }
    .box3{
      float: left;
    }

    .box4{
      width: 200px;
      height: 100px;
      background-color: purple;
      float: left;
    }


  </style>
</head>
<body>
  <div class="container">
    <div class="item box1">1</div>
    <div class="item box2">2</div>
    <div class="item box3">3</div>
    <div class="item box4">4</div>
  </div>
  
</body>
</html>